3.3.56 \(\int \frac {\cos (e+f x)}{\sqrt {d \tan (e+f x)}} \, dx\) [256]

Optimal. Leaf size=76 \[ \frac {F\left (\left .e-\frac {\pi }{4}+f x\right |2\right ) \sec (e+f x) \sqrt {\sin (2 e+2 f x)}}{2 f \sqrt {d \tan (e+f x)}}+\frac {\cos (e+f x) \sqrt {d \tan (e+f x)}}{d f} \]

[Out]

-1/2*(sin(e+1/4*Pi+f*x)^2)^(1/2)/sin(e+1/4*Pi+f*x)*EllipticF(cos(e+1/4*Pi+f*x),2^(1/2))*sec(f*x+e)*sin(2*f*x+2
*e)^(1/2)/f/(d*tan(f*x+e))^(1/2)+cos(f*x+e)*(d*tan(f*x+e))^(1/2)/d/f

________________________________________________________________________________________

Rubi [A]
time = 0.06, antiderivative size = 76, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.210, Rules used = {2692, 2694, 2653, 2720} \begin {gather*} \frac {\cos (e+f x) \sqrt {d \tan (e+f x)}}{d f}+\frac {\sqrt {\sin (2 e+2 f x)} \sec (e+f x) F\left (\left .e+f x-\frac {\pi }{4}\right |2\right )}{2 f \sqrt {d \tan (e+f x)}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Cos[e + f*x]/Sqrt[d*Tan[e + f*x]],x]

[Out]

(EllipticF[e - Pi/4 + f*x, 2]*Sec[e + f*x]*Sqrt[Sin[2*e + 2*f*x]])/(2*f*Sqrt[d*Tan[e + f*x]]) + (Cos[e + f*x]*
Sqrt[d*Tan[e + f*x]])/(d*f)

Rule 2653

Int[1/(Sqrt[cos[(e_.) + (f_.)*(x_)]*(b_.)]*Sqrt[(a_.)*sin[(e_.) + (f_.)*(x_)]]), x_Symbol] :> Dist[Sqrt[Sin[2*
e + 2*f*x]]/(Sqrt[a*Sin[e + f*x]]*Sqrt[b*Cos[e + f*x]]), Int[1/Sqrt[Sin[2*e + 2*f*x]], x], x] /; FreeQ[{a, b,
e, f}, x]

Rule 2692

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Simp[(-(a*Sec[e +
f*x])^m)*((b*Tan[e + f*x])^(n + 1)/(b*f*m)), x] + Dist[(m + n + 1)/(a^2*m), Int[(a*Sec[e + f*x])^(m + 2)*(b*Ta
n[e + f*x])^n, x], x] /; FreeQ[{a, b, e, f, n}, x] && (LtQ[m, -1] || (EqQ[m, -1] && EqQ[n, -2^(-1)])) && Integ
ersQ[2*m, 2*n]

Rule 2694

Int[sec[(e_.) + (f_.)*(x_)]/Sqrt[(b_.)*tan[(e_.) + (f_.)*(x_)]], x_Symbol] :> Dist[Sqrt[Sin[e + f*x]]/(Sqrt[Co
s[e + f*x]]*Sqrt[b*Tan[e + f*x]]), Int[1/(Sqrt[Cos[e + f*x]]*Sqrt[Sin[e + f*x]]), x], x] /; FreeQ[{b, e, f}, x
]

Rule 2720

Int[1/Sqrt[sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[(2/d)*EllipticF[(1/2)*(c - Pi/2 + d*x), 2], x] /; FreeQ
[{c, d}, x]

Rubi steps

\begin {align*} \int \frac {\cos (e+f x)}{\sqrt {d \tan (e+f x)}} \, dx &=\frac {\cos (e+f x) \sqrt {d \tan (e+f x)}}{d f}+\frac {1}{2} \int \frac {\sec (e+f x)}{\sqrt {d \tan (e+f x)}} \, dx\\ &=\frac {\cos (e+f x) \sqrt {d \tan (e+f x)}}{d f}+\frac {\sqrt {\sin (e+f x)} \int \frac {1}{\sqrt {\cos (e+f x)} \sqrt {\sin (e+f x)}} \, dx}{2 \sqrt {\cos (e+f x)} \sqrt {d \tan (e+f x)}}\\ &=\frac {\cos (e+f x) \sqrt {d \tan (e+f x)}}{d f}+\frac {\left (\sec (e+f x) \sqrt {\sin (2 e+2 f x)}\right ) \int \frac {1}{\sqrt {\sin (2 e+2 f x)}} \, dx}{2 \sqrt {d \tan (e+f x)}}\\ &=\frac {F\left (\left .e-\frac {\pi }{4}+f x\right |2\right ) \sec (e+f x) \sqrt {\sin (2 e+2 f x)}}{2 f \sqrt {d \tan (e+f x)}}+\frac {\cos (e+f x) \sqrt {d \tan (e+f x)}}{d f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [C] Result contains complex when optimal does not.
time = 0.60, size = 126, normalized size = 1.66 \begin {gather*} \frac {\cos (2 (e+f x)) \sec (e+f x) \left (\sqrt [4]{-1} F\left (\left .i \sinh ^{-1}\left (\sqrt [4]{-1} \sqrt {\tan (e+f x)}\right )\right |-1\right ) \sec ^2(e+f x)-\sqrt {\sec ^2(e+f x)} \sqrt {\tan (e+f x)}\right ) \sqrt {\tan (e+f x)}}{f \sqrt {\sec ^2(e+f x)} \sqrt {d \tan (e+f x)} \left (-1+\tan ^2(e+f x)\right )} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Cos[e + f*x]/Sqrt[d*Tan[e + f*x]],x]

[Out]

(Cos[2*(e + f*x)]*Sec[e + f*x]*((-1)^(1/4)*EllipticF[I*ArcSinh[(-1)^(1/4)*Sqrt[Tan[e + f*x]]], -1]*Sec[e + f*x
]^2 - Sqrt[Sec[e + f*x]^2]*Sqrt[Tan[e + f*x]])*Sqrt[Tan[e + f*x]])/(f*Sqrt[Sec[e + f*x]^2]*Sqrt[d*Tan[e + f*x]
]*(-1 + Tan[e + f*x]^2))

________________________________________________________________________________________

Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(197\) vs. \(2(93)=186\).
time = 0.33, size = 198, normalized size = 2.61

method result size
default \(-\frac {\left (\cos \left (f x +e \right )-1\right ) \left (\sqrt {\frac {\cos \left (f x +e \right )-1}{\sin \left (f x +e \right )}}\, \sqrt {\frac {-1+\cos \left (f x +e \right )+\sin \left (f x +e \right )}{\sin \left (f x +e \right )}}\, \sqrt {-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}}\, \sin \left (f x +e \right ) \EllipticF \left (\sqrt {-\frac {-1+\cos \left (f x +e \right )-\sin \left (f x +e \right )}{\sin \left (f x +e \right )}}, \frac {\sqrt {2}}{2}\right )-\left (\cos ^{2}\left (f x +e \right )\right ) \sqrt {2}+\cos \left (f x +e \right ) \sqrt {2}\right ) \left (\cos \left (f x +e \right )+1\right )^{2} \sqrt {2}}{2 f \sin \left (f x +e \right )^{3} \cos \left (f x +e \right ) \sqrt {\frac {d \sin \left (f x +e \right )}{\cos \left (f x +e \right )}}}\) \(198\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(f*x+e)/(d*tan(f*x+e))^(1/2),x,method=_RETURNVERBOSE)

[Out]

-1/2/f*(cos(f*x+e)-1)*(((cos(f*x+e)-1)/sin(f*x+e))^(1/2)*((-1+cos(f*x+e)+sin(f*x+e))/sin(f*x+e))^(1/2)*(-(-1+c
os(f*x+e)-sin(f*x+e))/sin(f*x+e))^(1/2)*sin(f*x+e)*EllipticF((-(-1+cos(f*x+e)-sin(f*x+e))/sin(f*x+e))^(1/2),1/
2*2^(1/2))-cos(f*x+e)^2*2^(1/2)+cos(f*x+e)*2^(1/2))*(cos(f*x+e)+1)^2/sin(f*x+e)^3/cos(f*x+e)/(d*sin(f*x+e)/cos
(f*x+e))^(1/2)*2^(1/2)

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(f*x+e)/(d*tan(f*x+e))^(1/2),x, algorithm="maxima")

[Out]

integrate(cos(f*x + e)/sqrt(d*tan(f*x + e)), x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(f*x+e)/(d*tan(f*x+e))^(1/2),x, algorithm="fricas")

[Out]

integral(sqrt(d*tan(f*x + e))*cos(f*x + e)/(d*tan(f*x + e)), x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\cos {\left (e + f x \right )}}{\sqrt {d \tan {\left (e + f x \right )}}}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(f*x+e)/(d*tan(f*x+e))**(1/2),x)

[Out]

Integral(cos(e + f*x)/sqrt(d*tan(e + f*x)), x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(f*x+e)/(d*tan(f*x+e))^(1/2),x, algorithm="giac")

[Out]

integrate(cos(f*x + e)/sqrt(d*tan(f*x + e)), x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\cos \left (e+f\,x\right )}{\sqrt {d\,\mathrm {tan}\left (e+f\,x\right )}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(e + f*x)/(d*tan(e + f*x))^(1/2),x)

[Out]

int(cos(e + f*x)/(d*tan(e + f*x))^(1/2), x)

________________________________________________________________________________________